<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>
<?php 
    if(isset($this->pageTitle)){
        echo $this->pageTitle;
    }else {
        $config = config::get('info');
        echo $config['pageTitle'];
    }
 ?>
</title>
<link rel="stylesheet" href="/css/screen.css" type="text/css" media="screen" title="default" />
<link rel="stylesheet" href="/js/jquery/themes/ui-darkness/jquery.ui.all.css">
<script src="/js/common.js" type="text/javascript"></script> 
<script src="/js/jx.js" type="text/javascript"></script>
<script src="/js/rc.js" type="text/javascript"></script>
<?php 
	if($this->enableJquery == "")
	{
 ?>
<link type="text/css" href="/js/jquery/css/themename/jquery-ui-1.8.24.custom.css" rel="Stylesheet" />	
<script type="text/javascript" src="/js/jquery/js/jquery-1.8.2.min.js"></script>
<script type="text/javascript" src="/js/jquery/js/jquery-ui-1.8.24.custom.min.js"></script>

<script src="/js/jquery/development-bundle/ui/jquery.ui.dialog.js"></script>
<link rel="stylesheet" href="/js/jquery/development-bundle/demos/demos.css">
<link rel="stylesheet" href="/js/jquery/development-bundle/themes/base/jquery.ui.all.css">

<?php
	}
 ?>

<style type="text/css">
	.nav li {
		float: left;
		height: auto;
		margin: 0;
		padding: 0;
	}
</style>
</head>
<body>
<textarea id="log" style="display:none;width:100%;height:200px"></textarea>
<input type="hidden" id="isFirstButton" value="0" />
<div class="clear">&nbsp;</div>
<!--  start nav-outer-repeat................................................................................................. START -->
<div class="nav-outer-repeat"> 
<!--  start nav-outer -->
<div class="nav-outer"> 

		<!-- start nav-right -->
		<div id="nav-right">
		<?php
            global $auth;
            $user = $auth->getIdentity();
            if((int)$user->USERID != 0)
            {
        ?>
			<div class="nav-divider">&nbsp;</div>
			<a href="<?php echo $this->baseUrl("/auth/logout/index");?>" id="logout"><img src="/images/shared/nav/nav_logout.gif" width="100" height="14" alt="" /></a>
			<div class="clear">&nbsp;</div>

			<!--  start account-content -->
			<div class="account-content">
			</div>
			<!--  end account-content -->
		<?php } else { ?>

            <div class="nav-divider">&nbsp;</div>
			<div class="nav-divider">&nbsp;</div>
			<a href="<?php echo $this->baseUrl("/auth/logout/index");?>" id="logout"><img src="/images/shared/nav/dang-nhap.gif" width="100" height="14" alt="" /></a>
			<div class="clear">&nbsp;</div>

			<!--  start account-content -->
			<div class="account-content">
			</div>
			<!--  end account-content -->

        <?php } ?>
		</div>
		<!-- end nav-right -->

		<div class="nav">
		<ul class="sf-menu">	
			<li class="current">
				<a href="/admin/deal/index">Quản lý Deal</a>
			</li>
			<div class="nav-divider"></div>
             <li class="current">
             	 <a href="/admin/store/index">Quản lý Store</a>
			</li>
			<div class="nav-divider"></div>
            <li class="current">
                <a href="/admin/users/index">Quản lý người dùng</a>
			</li>
			<div class="nav-divider"></div>
			<li class="current">
				<a href="/admin/roles/index">Quản lý phân quyền</a>
			</li>
			<div class="nav-divider"></div>
			<li class="current">
				<a href="/admin/dealcategories/index">Cài đặt chung</a>
			</li>
			<div class="nav-divider"></div>
			<li class="current">
				<a href="/generate/index/index">Xây dựng module</a>
			</li>
			
		</ul>
		</div>

</div>

<!--  start nav-outer -->
</div>
<!--  start nav-outer-repeat................................................... END -->
 
<!-- start content-outer -->
<div id="content-outer">
<!-- start content -->
	<div id="content">
		<div id="page-heading">
			<div id="page-heading-title" ><h1><?=$this->maintitle?></h1></div>
			<div>&nbsp;</div>
		</div>

		<table border="0" width="100%"  cellpadding="0" cellspacing="0" id="content-table">
			<tr>
				<th rowspan="3" class="sized"><img src="/images/shared/side_shadowleft.jpg" width="20" height="300" alt="" /></th>
				<th class="topleft"></th>
				<td id="tbl-border-top">&nbsp;</td>
				<th class="topright"></th>
				<th rowspan="3" class="sized"><img src="/images/shared/side_shadowright.jpg" width="20" height="300" alt="" /></th>
			</tr>
			<tr>
				<td id="tbl-border-left"></td>
				<td>
				<!--  start content-table-inner -->
				<div id="content-table-inner">
				
					<table border="0" width="100%" cellpadding="0" cellspacing="0">
						<tr valign="top">
							<td width="80%">
							<!--  start table-content  -->
								<div id="table-content">
									<h2><?=$this->title?> </h2>
									<h3><?=$this->subtitle?></h3>
									<!-- locate REGION_HARD_FORM| -->
									
									<div id="hard_content">
										<!-- locate REGION_HARD_CONTENT| -->
									   
									</div>
									<div id="main_content" >
										<!-- locate REGION_CONTENT| -->
										<?php echo $this->layout()->content ?>
									</div>
								</div>
							</td>
							<td>	
								<!--  start related-activities -->
								<!-- locate REGION_RIGHT_MENU| -->
								<div id="related-activities">
									
									<!--  start related-act-top -->
									<div id="related-act-top">
									<img src="/images/forms/header_related_act.gif" width="271" height="43" alt="" />
									</div>
									<!-- end related-act-top -->
									<!--  start related-act-bottom -->
									<div id="related-act-bottom">
										<!--  start related-act-inner -->
										<div id="related-act-inner">			
											<div class="right">
												<ul class="greyarrow">
													<li><a href="/admin/dealcategories/index">Deal Categories</a></li>
													<div>&nbsp;</div>
													<li><a href="/admin/storecategories/index">Store Categories</a></li>
													<div>&nbsp;</div>
													<li><a href="/admin/price/index">Price Config</a></li>
												</ul>
											</div>
											<div class="clear"></div>
											<div class="lines-dotted-short"></div>
											<div class="clear"></div>	
										</div>
										<!-- end related-act-inner -->
										<div class="clear"></div>
									</div>
									<!-- end related-act-bottom -->
								</div>
								<!-- end related-activities -->
							</td>
						</tr>
						<tr>
							<td><img src="/images/shared/blank.gif" width="695" height="1" alt="blank" /></td>
							<td></td>
						</tr>
					</table>
			 
					<div class="clear"></div>
				</div>
				<!--  end content-table-inner  -->
				</td>
				<td id="tbl-border-right"></td>
			</tr>
			<tr>
				<th class="sized bottomleft"></th>
				<td id="tbl-border-bottom">&nbsp;</td>
				<th class="sized bottomright"></th>
			</tr>
		</table>
		<div class="clear">&nbsp;</div>
	</div>
	<!--  end content -->
	<div class="clear">&nbsp;</div>
</div>
<!--  end content-outer -->
<div class="clear">&nbsp;</div>
    
<!-- start footer -->         
<div id="footer">
	<!--  start footer-left -->
	<div id="footer-left">
	
        </div>
	<!--  end footer-left -->
	<div class="clear">&nbsp;</div>
</div>
<!-- end footer -->
</body>
</html>